With regard to the AC rotary machine control device as described above, an electric rotating machine disclosed in PLT 1 is known. In the technology of PLT 1, the content of the 5th order harmonic wave included in the AC rotary machine is detected, and the 5th order harmonic wave voltage command is calculated based on the detected harmonic wave content and output voltage, and the inverter is controlled based on the output voltage command on which the 5th order harmonic wave voltage command superimposed.